def deep_get(config, key_list, default=None):
    for key in key_list:
        if isinstance(config, dict):
            config = config.get(key, default)
        else:
            return default
    return config
